<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>项目评级问答-欢迎页</title>
<link href="__PUBLIC__/admin/css/style.css" rel="stylesheet" type="text/css" />
<script language="JavaScript" src="__PUBLIC__/admin/js/jquery.js"></script>

<link href="__PUBLIC__/admin/css/select.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="__PUBLIC__/admin/js/jquery.idTabs.min.js"></script>
<script type="text/javascript" src="__PUBLIC__/admin/js/select-ui.min.js"></script>

<link href="__PUBLIC__/validform/Validform.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="__PUBLIC__/validform/Validform_v5.3.2.js"></script>
<script type="text/javascript" src="__PUBLIC__/validform/Validform_Datatype.js"></script>

<script type="text/javascript">
$(document).ready(function(e) {
    $("#indus_id,#item_province,#item_city").uedSelect({
		width : 150			  
	});
});
</script>
</head>

<body>

	<div class="place">
		<span>位置：</span>
		<ul class="placeul">
			<li><a href="{:U('index/welcome')}">首页</a></li>
			<li><a href="{:U('itemrate/index')}">项目评级</a></li>
			<li><a href="#">项目评级问答</a></li>
		</ul>
    </div>
    
    <div class="formbody">
		<div class="formtitle"><span>项目评级（项目评级问答）[{$iteminfo.item_name}]</span></div>
		<form id="rateform" name="rateform" action="{:U('itemrate/rateing',array('item_id'=>$iteminfo['item_id']))}" method="post">
			<volist name="rateinfo" id="topcate" key="k">
				<div class="formtitle" style="clear:both;"><span>{$k}、{$topcate.top_name}</span></div>
				<ul class="forminfo">
				<volist name="topcate.subcate" id="subcate" key="key">
					<li><label> {$subcate.sub_name}</label>
					<if condition="$subcate.sub_type eq '1' "><!--单选-->
						<volist name="subcate.threecate" id="threecate">
						<label><input name="info[{$subcate.sub_id}]" type="radio" value="{$threecate.three_id}" datatype="*" errormsg="不能为空！" />{$threecate.three_name}</label>
						</volist>
						<i class="Validform_checktip"></i>
					<elseif condition="$subcate.sub_type eq '2' " /><!--多选-->
						<volist name="subcate.threecate" id="threecate">
						<label><input name="info[{$subcate.sub_id}][]" type="checkbox" value="{$threecate.three_id}" datatype="*" errormsg="不能为空！"/>{$threecate.three_name}</label>
						</volist>
						<i class="Validform_checktip"></i>
					<elseif condition="$subcate.sub_type eq '3' " /><!--数字填写-->
						<volist name="subcate.threecate" id="threecate">
						<div style="clear:both;margin-left: 86px;">
						<label>{$threecate.three_name}:</label><input name="info[{$subcate.sub_id}][{$threecate.three_id}]" type="text" value="" datatype="*" errormsg="不能为空！" class="dfinput" style="width:50px;height:24px;" /><i class="Validform_checktip"></i><br>
						</div>
						</volist>
					<elseif condition="$subcate.sub_type eq '4' " /><!--描述填写-->
						<volist name="subcate.threecate" id="threecate">
						<!--<label>{$threecate.three_name}</label>-->
						<textarea name="info[{$subcate.sub_id}][{$threecate.three_id}]" cols="" rows="" class="textinput" style="width: 300px;height: 100px;" datatype="*" errormsg="不能为空！" maxlength="200"></textarea><i class="Validform_checktip"></i>
						</volist>
					</if>
					</li>
				</volist>
				</ul>
			</volist>
			<ul class="forminfo" style="padding-top:20px;clear:both;">
				<li><label>&nbsp;</label><input name="loginbtn" type="submit" class="btn" value="确认保存"/></li>
			</ul>
		</form>
    
    </div>

	<script>
	$(function(){
		$("#rateform").Validform({
			tiptype:1
			/*
			tiptype:function(msg,o,cssctl){
				var objtip=o.obj.siblings(".Validform_checktip");
				cssctl(objtip,o.type);
				objtip.text(msg);
			}
			*/
		});

		$(":text").keyup(function(){
			var v=$(this).val();
			$(this).attr("maxlength",5);
			$(this).val(v.replace(/[^\-?\d.]/g,''));
		});
	}); 
	</script>
</body>

</html>
